<!DOCTYPE html>
<html lang="en">
<head>
	<title></title>
	<meta charset="UTF-8"/>
	<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/bootstrap.min.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/bootstrap-responsive.min.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/uniform.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/matrix-style2.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/matrix-media.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/font-awesome/css/font-awesome.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<link rel="stylesheet" href="__PUBLIC__/Admin/css/changyun.css?v={#$Think.config.ADMIN_VERSION_VAL}"/>
	<style>
		.control-group .controls label {
			display: inline-block;
		}

		ul, li {
			list-style: none;
		}

		.upload_img_list {
			width: 100%;
			display: block;
		}

		.upload_img_list li {
			float: left;
			margin-right: 5px;
			margin-bottom: 10px;
		}

		.upload_img_list li img {
			width: 80px;
			height: 80px;
			border: 1px solid #cccccc;
			padding: 1px;
		}

		.tab_on_select {
			background: #5bb75b;
		}

		.tab_on_select a {
			color: #ffffff;
		}

		.upload_img_list_350_476 {
			width: 100%;
			display: block;
		}

		.upload_img_list_350_476 li {
			float: left;
			margin-right: 5px;
			margin-bottom: 10px;
		}

		.upload_img_list_350_476 li img {
			width: 350px;
			height: 476px;
			border: 1px solid #cccccc;
			padding: 1px;
		}
	</style>
</head>
<body>
<div id="content">

	<include file="Public/maintop"/>

	<div class="container-fluid">
		<div class="row-fluid">
			<div class="span12">

				<div class="widget-box">
					<div class="widget-content tab-content">
						<div id="tab1" class="tab-pane active">
							<div class="widget-content nopadding">
								<form action="{#$this_url_action}" method="post" class="form-horizontal" id="form_basic_validate">
									<div class="control-group">
										<label class="control-label">生成数量 :</label>
										<div class="controls">
											<input type="text" class="span1" id="number" name="number" value="{#$info.number}">
										</div>
									</div>
									<div class="control-group">
										<label class="control-label">vip天数 :</label>
										<div class="controls">
											<input type="text" class="span1" id="vip_day" name="vip_day" value="{#$info.vip_day}">
										</div>
									</div>
									<div class="form-actions">
										<input type="hidden" name="id" value="{#$info.id|default=''}">
										<button type="submit" class="btn btn-success">保存</button>
									</div>
								</form>
							</div>

						</div>
					</div>
				</div>

			</div>
		</div>
		<hr>
	</div>
</div>
</div>
<textarea id="upload_editor" style="width: 0;height: 0;display: none;"></textarea>
<script src="__PUBLIC__/Admin/js/jquery.min.js"></script>
<script src="__PUBLIC__/Admin/js/jquery.ui.custom.js"></script>
<script src="__PUBLIC__/Admin/js/bootstrap.min.js"></script>
<script src="__PUBLIC__/Admin/js/jquery.uniform.js"></script>
<script src="__PUBLIC__/Admin/js/matrix.js"></script>
<script src="__PUBLIC__/Admin/js/matrix.tables.js"></script>
<script src="__PUBLIC__/js/layer/layer.js"></script>
<script src="__PUBLIC__/js/Validform.min.js"></script>
<script src="__PUBLIC__/ueditor/ueditor.config.js" type="text/javascript"></script>
<script src="__PUBLIC__/ueditor/ueditor.all.min.js" type="text/javascript"></script>
<script type="text/javascript" charset="utf-8" src="__PUBLIC__/ueditor/lang/zh-cn/zh-cn.js"></script>
<script type="text/javascript">
var ue_uploader = UE.getEditor('upload_editor', {serverUrl: "{#:U('NewUpload/upload')}"});

function upOneImage(fname) {
	ue_uploader.ready(function() {
		var pickey = 1;
		ue_uploader.addListener('beforeInsertImage', function(t, arg) {
			if (pickey == 1) {
				$("#" + fname + "_one_data").html('<li><img src="' + arg[0].src + '" /></li>');
				$("#" + fname).val(arg[0].src);
			}
			pickey++;
		});
	});
	var myImage = ue_uploader.getDialog("insertimage");
	myImage.open();
}

$("#btn_url_select").click(function() {
	layer.open({
		type: 2,
		title: '选择地址',
		shadeClose: true,
		shade: 0.3,
		maxmin: false,
		area: ['893px', '600px'],
		content: "{#:U('Link/getLinkData')}"
	});
});
$(function() {
	changeType("{#$info.jump_type}");
})

function changeType() {
	var this_val = $("input[name='jump_type']:checked").val();
	if (this_val == 1) {
		$(".is_show_appid_div").show();
	} else {
		$(".is_show_appid_div").hide();
	}
}
</script>
<script type="text/javascript">
$(function() {
	$('input[type=checkbox],input[type=radio],input[type=file]').uniform();
	var loadi = null;
	var demo1 = $("#form_basic_validate").Validform({
		tiptype: 3,
		ajaxPost: true,
		postonce: true,
		tiptype: function(msg, o, cssctl) {
			if (!o.obj.is("form")) {
				var objtip = o.obj.siblings(".Validform_checktip");
				cssctl(objtip, o.type);
				objtip.text(msg);
			}
		},
		beforeSubmit: function(curform) {
			loadi = layer.load('表单正在处理中，请稍等 ...');
		},
		callback: function(data) {
			layer.close(loadi);
			if (data.status == 1) {
				layer.alert(data.msg, {icon: 1}, function() {
					window.location.href = "{#:U('vipSetting')}";
				});
			} else {
				layer.alert(data.msg, {icon: 0});
			}
		}
	});
})
</script>
</body>
</html>
